We present J and K-band luminosity functions (LF) for the Group Evolution Multiwavelength Study (GEMS) sample of 60 nearby groups of galaxies, with photometry from the 2MASS survey. We find that, as seen in B and R-band photometry of a subsample of these groups in our earlier work, the LFs of the X-ray dim groups (L_X < 10^41.7 erg/s) show a depletion of galaxies of intermediate luminosity around M_K = -23, within a radius 0.3R_500 from the centres of these groups. This feature is not seen in the X-ray brighter groups, nor in either kind of group when the LFs are determined all the way out to R_500. We conclude that an enhanced level of star formation is not responsible for the this feature. From the faint end of the LFs, we find support for the under-abundance of low surface brightness dwarfs in the 2MASS survey. We find that for all kinds of groups, the modelling of the luminosity function, with universal forms for the LFs of galaxies of different morphological types, fails when simultaneously required to fit the B and K-band LFs. This means that the dip-like features seen in LFs are not merely due to the varying proportions of galaxies of different morphological types among the X-ray dim and bright groups. We argue that this support our hypothesis that this feature is due to the enhanced merging of intermediate-mass galaxies in the dynamically sluggish environment of X-ray dim groups.